The present invention, in some embodiments thereof, relates to touch emulation and, more particularly, but not exclusively, to touch emulation using navigation keys.
Many modern consumer electronics products have a touch based interface, making touch the main input method. Most application developers develop their applications with only a touch interface. When an application is built with touch interface, it means that the application responds to finger presses on some 2-dimensional coordinates (x,y) on a screen.
An operating system may be used for different products, some having a touch based interface, while others having no touch interface and may only be controlled by navigation keys.
A simple approach of emulating touch interface with navigation keys is using a mouse cursor that moves in position according to the navigation keys control, i.e. pressing the up, down, left or right key will move the mouse cursor one or more pixel up, down, left or right respectively. Multiple or long presses of the same navigation key may move the cursor faster, over more pixels, in the same direction. In some optimizations of this approach, a long press causes the cursor to accelerate rather than move in a fixed speed.
When used on large screens, composed of thousands of pixels in each coordinate, this approach is inefficient as it still takes a significant amount of time to reach the position that the user would like to press. Specifically, this pixel by pixel movement is not optimal for a user interface (UI) that is composed of widgets, each taking a large area of hundreds or thousands of pixels on the screen.
The UI of most modern applications is composed of a hierarchical layout of UI widgets. In order for a UI widget to be controlled by touch, some widgets are defined with a touch responsiveness property. The touch responsiveness property indicates that the widget has an implementation that runs whenever the user touches that widget. The touch event by the user may also change the appearance of that widget or some other widgets on screen. For example, whenever the user presses a button widget by touching the button on the screen, the widget's UI changes to a “pressed” state and when the user releases his finger from the button, the widget's UI changes back to a “released” state. There are some widgets that are not defined with a touch responsiveness property and are not controllable by a touch, for example, a static text view widget that is displayed on screen.
Some applications designed to be operated by touch are also designed to be operable by navigation keys. This is done by defining a “focusable” property indicating that a widget may be selected by navigation keys.